﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;
using System.Xml.Serialization;

namespace ForumsBrowser.DataObjects
{
    [XmlRoot("user")]
    public class User : IGuidIdObject
    {
        [XmlAttribute("id")]
        public Guid Id { get; set; }

        [XmlElement("displayName")]
        public string DisplayName { get; set; }

        [XmlElement("microsoft")]
        public bool Microsoft { get; set; }

        [XmlElement("mvp")]
        public bool MVP { get; set; }

        [XmlElement("partner")]
        public bool Partner { get; set; }

        [XmlElement("smallImage")]
        public string SmallImageUrl { get; set; }

        [XmlElement("largeImage")]
        public string LargeImageUrl { get; set; }

        [XmlElement("xlargeImage")]
        public string XLargeImageUrl { get; set; }

        [XmlElement("url")]
        public string Url { get; set; }

        [XmlElement("lastActive")]
        public string LastActive { get; set; }

        [XmlElement("points")]
        public int Points { get; set; }

        [XmlElement("posts")]
        public int Posts { get; set; }

        [XmlElement("answers")]
        public int Answers { get; set; }

        [XmlElement("stars")]
        public int Stars { get; set; }

        [XmlElement("threadsUrl")]
        public string ThreadsUrl { get; set; }

        [XmlElement("isInappropriate")]
        public bool IsInappropriate { get; set; }

        public override string ToString()
        {
            return DisplayName;
        }
    }
}
